package com.atguigu.yygh.hosp.controller.admin;

import com.atguigu.yygh.result.R;
import com.atguigu.yygh.vo.acl.UserQueryVo;
import org.springframework.web.bind.annotation.*;

/**
 * @author A
 * @version 1.0
 * @description: TODO
 * @date 2025/3/12 2:41
 */
@RestController
@RequestMapping("/admin/user")
public class UserController {
    @PostMapping("/login")
    public R userLogin(@RequestBody UserQueryVo userQueryVo) {
        System.out.println(userQueryVo);
        // 登录逻辑
        return R.ok().data("token","admin-token");
    }
    @GetMapping("/info")
    public R userInfo() {
        // 获取用户信息
        return R.ok().data("roles","admin")
                .data("introduction","I am a super administrator")
                .data("avatar","https://ts1.tc.mm.bing.net/th/id/R-C.57b454584fb4c3ac87a4f06996b0a58a?rik=SuXESdrmpxe%2btw&riu=http%3a%2f%2fn.sinaimg.cn%2ftranslate%2f20170725%2f3vjK-fyiiahz0296204.gif&ehk=KFlw1xM6XOf7MoQV6%2bRQWh1cmS6fYLXkJe31oJnv44w%3d&risl=&pid=ImgRaw&r=0")
                .data("name","Super Admin");
    }
}
